﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using IOBusiness.LinqDB;

namespace IOBusiness.ClassLinq
{
    public class clsLqAbout    
    {
        SapaDBDataContext objDBData = new SapaDBDataContext();

        public tblAboutUS About_getByid(int id)
        {
            tblAboutUS t = new tblAboutUS();
            t = objDBData.tblAboutUS.SingleOrDefault(ta=>ta.ID==id);
            return t;
        }

        public List<tblAboutUS> About_getAll()
        {
            try
            {
                var select = from aboutUs in objDBData.tblAboutUS
                             select aboutUs;
                return select.ToList<tblAboutUS>();
            }
            catch (Exception)
            {

                throw;
            }
        }
    }
}
